import axios from '@/libs/api.request'

export const getList = info => {
  return axios.request({
    url: 'productShop/getList',
    data: info,
    method: 'post'
  })
}

export const add = info => {
  return axios.request({
    url: 'productShop/insertEnter',
    data: info,
    method: 'post'
  })
}

export const addView = info => {
  return axios.request({
    url: 'productShop/addView',
    data: info,
    method: 'post'
  })
}

export const addProd = info => {
  return axios.request({
    url: 'productShop/insertEnterAllot',
    data: info,
    method: 'post'
  })
}

export const delProd = info => {
  return axios.request({
    url: 'product/deleteEnterAllot',
    data: info,
    method: 'post'
  })
}

export const detail = info => {
  // 新增 修改调取，获取分类
  return axios.request({
    url: 'productShop/detail',
    data: info,
    method: 'post'
  })
}

export const detailProd = info => {
  return axios.request({
    url: 'productShop/storeProductDetail',
    data: info,
    method: 'post'
  })
}

export const put = info => {
  return axios.request({
    url: 'productShop/updateEnter',
    data: info,
    method: 'post'
  })
}

export const del = info => {
  return axios.request({
    url: 'productShop/del',
    data: info,
    method: 'post'
  })
}
export const getDetail = info => {
  return axios.request({
    url: 'productShop/detail',
    data: info,
    method: 'post'
  })
}

export const getVenueList = info => {
  return axios.request({
    url: 'productShop/getVenueList',
    data: info,
    method: 'post'
  })
}
export const estate = info => {
  return axios.request({
    url: 'productShop/estate',
    data: info,
    method: 'post'
  })
}
export const getProductBallModel = info => {
  return axios.request({
    url: 'productShop/getProductBallModel',
    data: info,
    method: 'post'
  })
}

export const setPrive = info => {
  return axios.request({
    url: 'productShop/setPrive',
    data: info,
    method: 'post'
  })
}
export const setModelEstate = info => {
  return axios.request({
    url: 'productShop/setModelEstate',
    data: info,
    method: 'post'
  })
}
export const setSessionsEstate = info => {
  return axios.request({
    url: 'productShop/setSessionsEstate',
    data: info,
    method: 'post'
  })
}

export const editSessionsDate = info => {
  return axios.request({
    url: 'productShop/editSessionsDate',
    data: info,
    method: 'post'
  })
}

export const batchSetPrive = info => {
  return axios.request({
    url: 'productShop/batchSetPrive',
    data: info,
    method: 'post'
  })
}

export const modeSwitch = info => {
  return axios.request({
    url: 'productShop/modeSwitch',
    data: info,
    method: 'post'
  })
}

export const getBallModelLog = info => {
  return axios.request({
    url: 'pproductShop/getBallModelLog',
    data: info,
    method: 'post'
  })
}

export const setDaysPrive = info => {
  return axios.request({
    url: 'productShop/setDaysPrive',
    data: info,
    method: 'post'
  })
}

export const downImg = info => {
  return axios.request({
    url: 'product/downImg',
    params: info,
    method: 'get'
  })
}

export const getProdlist = info => {
  return axios.request({
    url: 'product/storeProductList',
    data: info,
    method: 'post'
  })
}

export const getnormstemplateformat = info => {
  return axios.request({
    url: 'productShop/getnormstemplateformat',
    data: info,
    method: 'post'
  })
}

export const setAudit = info => {
  return axios.request({
    url: 'product/Audit',
    data: info,
    method: 'post'
  })
}

export const getLibraryList = info => {
  return axios.request({
    url: 'product/productLibrary',
    data: info,
    method: 'post'
  })
}
export const courseDetail = info => {
  return axios.request({
    url: 'productShop/detail',
    data: info,
    method: 'post'
  })
}
export const getUserData = info => {
  return axios.request({
    url: 'index/getUserList',
    data: info,
    method: 'post'
  })
}
